package Eyjafjalla.relic;

import Eyjafjalla.helper.StringHelper;
import basemod.abstracts.CustomRelic;
import com.megacrit.cardcrawl.actions.common.HealAction;
import com.megacrit.cardcrawl.actions.common.RelicAboveCreatureAction;
import com.megacrit.cardcrawl.dungeons.AbstractDungeon;
import com.megacrit.cardcrawl.helpers.ImageMaster;
import com.megacrit.cardcrawl.relics.AbstractRelic;

public class VolcanoMask extends CustomRelic {

    public static final String ID = "eyjafjalla:VolcanoMask";

    public VolcanoMask(){
        super(ID, ImageMaster.loadImage(StringHelper.getRelicIMGPATH(ID,false)),ImageMaster.loadImage(StringHelper.getRelicIMGPATH(ID,true)),RelicTier.SPECIAL,LandingSound.SOLID);
    }

    boolean triggerThisTurn = false;

    @Override
    public void atTurnStart() {
        triggerThisTurn = false;
    }

    @Override
    public void onTrigger() {
        if(!triggerThisTurn){
            triggerThisTurn = true;
            this.flash();
            addToBot(new RelicAboveCreatureAction(AbstractDungeon.player,this));
            addToBot(new HealAction(AbstractDungeon.player,AbstractDungeon.player,1));
        }
    }

    @Override
    public String getUpdatedDescription() {
        return DESCRIPTIONS[0];
    }

    @Override
    public AbstractRelic makeCopy() {
        return new VolcanoMask();
    }
}




